#define  _CRT_SECURE_NO_WARNINGS
#include"Stack.h"
#include"Queue.h"

void StackTest()
{
	Stack st;
	StackInit(&st);
	StackPush(&st, 1);
	StackPush(&st, 2);
	StackPush(&st, 3);
	StackPush(&st, 4);
	StackPush(&st, 5);
	StackPop(&st);
	STDataType top = StackTop(&st);
	int num = StackSize(&st);
	int i = 0;
	for (i = 0; i < num; i++)
	{
		printf("%d\n", StackTop(&st));
		StackPop(&st);
	}
	StackDestroy(&st);
}
void QueueTest()
{
	Queue qu;
	QueueInit(&qu);
	QueuePush(&qu, 1);
	QueuePush(&qu, 2);
	QueuePush(&qu, 3);
	QueuePush(&qu, 4);
	QueuePush(&qu, 5);
	
	int tmp=QueueFront(&qu);
	printf("%d", tmp);
	tmp = QueueBack(&qu);
	printf("%d", tmp);
	tmp = QueueSize(&qu);
	printf("%d", tmp);
	tmp = QueueEmpty(&qu);
	printf("%d", tmp);
	QueueDestroy(&qu);

}


int main()
{
	//StackTest();
	QueueTest();
	
	return 0;
};